/* 基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: #f9fafb;
    font-family: 'Inter', system-ui, sans-serif;
    color: #1f2937;
    line-height: 1.5;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* 头部样式 */
header {
    background-color: #3b82f6;
    color: white;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    padding: 1.5rem 0;
}

header h1 {
    font-size: clamp(1.5rem, 3vw, 2.5rem);
    font-weight: 700;
    display: flex;
    align-items: center;
}

header p {
    color: #bfdbfe;
    margin-top: 0.25rem;
}

/* 主内容区样式 */
main {
    padding: 2rem 0;
}

section {
    margin-bottom: 2.5rem;
}

section h2 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
}

section h2 i {
    margin-right: 0.5rem;
    color: #3b82f6;
}

.card {
    background-color: white;
    border-radius: 0.75rem;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    padding: 1.5rem;
}

/* 状态卡片样式 */
.stats-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .stats-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.stat-card {
    background-color: #eff6ff;
    border: 1px solid #dbeafe;
    border-radius: 0.5rem;
    padding: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.stat-card .stat-info p {
    font-size: 0.875rem;
    font-weight: 500;
}

.stat-card .stat-info h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
    margin-top: 0.25rem;
}

.stat-card .stat-icon {
    background-color: #dbeafe;
    padding: 0.5rem;
    border-radius: 9999px;
}

.stat-card .stat-icon i {
    font-size: 1.25rem;
    color: #3b82f6;
}

/* 电梯可视化样式 */
.elevator-monitor {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 768px) {
    .elevator-monitor {
        grid-template-columns: 2fr 1fr;
    }
}

.elevators-container {
    display: flex;
    justify-content: space-around;
    align-items: flex-end;
    height: 400px;
}

.elevator-group {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.elevator-group h3 {
    font-weight: 600;
    margin-bottom: 0.5rem;
    text-align: center;
}

.elevator-shaft {
    background-color: #e5e7eb;
    width: 80px;
    height: 190px;
    position: relative;
    border-radius: 0.25rem;
    overflow: hidden;
}

.elevator-car {
    width: 70px;
    height: 60px;
    position: absolute;
    left: 5px;
    border-radius: 0.25rem;
    transition: bottom 1s ease-in-out;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.floor-indicator {
    position: absolute;
    left: -40px;
    width: 30px;
    text-align: right;
    font-size: 0.8rem;
}

.elevator-status {
    margin-top: 1rem;
    text-align: center;
    font-size: 0.875rem;
}

/* 楼层请求面板样式 */
.floor-request-panel {
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    padding: 1rem;
    height: 300px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.floor-request-panel h3 {
    font-weight: 600;
    margin-bottom: 1rem;
    text-align: center;
}

.floor-buttons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.floor-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.floor-row span {
    font-weight: 500;
}

.request-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s;
    background-color: #e5e7eb;
    color: #4b5563;
}

.request-btn:hover {
    transform: scale(1.1);
}

/* 电梯详情样式 */
.elevators-details {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .elevators-details {
        grid-template-columns: repeat(3, 1fr);
    }
}

.elevator-detail-card {
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    padding: 1rem;
}

.elevator-detail-card h3 {
    font-weight: 600;
    font-size: 1.125rem;
    margin-bottom: 0.75rem;
}

.detail-item {
    margin-bottom: 0.5rem;
    font-size: 0.875rem;
}

.detail-item span:first-child {
    color: #6b7280;
}

.target-floor-control {
    margin-top: 1rem;
}

.target-floor-control label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #4b5563;
    margin-bottom: 0.25rem;
}

.target-floor-control .control-group {
    display: flex;
}

.target-floor-control select {
    flex: 1;
    border: 1px solid #d1d5db;
    border-radius: 0.25rem 0 0 0.25rem;
    padding: 0.375rem 0.75rem;
}

.target-floor-control button {
    background-color: #3b82f6;
    color: white;
    padding: 0 0.75rem;
    border-radius: 0 0.25rem 0.25rem 0;
    border: none;
    cursor: pointer;
    transition: background-color 0.2s;
}

.target-floor-control button:hover {
    background-color: #2563eb;
}

/* 统计图表样式 */
.stats-charts {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .stats-charts {
        grid-template-columns: repeat(2, 1fr);
    }
}

.chart-container {
    height: 250px;
}

.chart-container h3 {
    font-weight: 600;
    margin-bottom: 0.75rem;
}

/* 页脚样式 */
footer {
    background-color: #1f2937;
    color: white;
    margin-top: 3rem;
    padding: 2rem 0;
}

footer .container {
    text-align: center;
}

footer p:first-child {
    margin-bottom: 0.5rem;
}

footer p:last-child {
    color: #9ca3af;
    font-size: 0.875rem;
}

/* 状态颜色类 - 补充定义 */
.bg-primary {
    background-color: #3B82F6; /* 蓝色 - 默认/空闲 */
}

.bg-secondary {
    background-color: #10B981; /* 绿色 - 向上运行 */
}

.bg-warning {
    background-color: #F59E0B; /* 黄色 - 向下运行 */
}

.bg-purple-500 {
    background-color: #A855F7; /* 紫色 - 门打开 */
}

.bg-danger {
    background-color: #EF4444; /* 红色 - 故障状态（预留） */
}

/* 文本颜色配合 */
.text-primary {
    color: #3B82F6;
}

.text-secondary {
    color: #10B981;
}

.text-warning {
    color: #F59E0B;
}

.text-purple-500 {
    color: #A855F7;
}

.text-danger {
    color: #EF4444;
}

/* 状态标签样式增强 */
.status-badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
    color: white;
}

